<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:c="http://java.sun.com/jsp/jstl/core"
	xmlns:rich="http://richfaces.org/rich"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:a4j="http://richfaces.org/a4j">
	
<body> 
 <ui:composition template="/templates/default/template.xhtml">
    <ui:define name="body">
    <h:form id="taomoidoanra">    
    <h:panelGrid columns="1" style="margin-left:5px;width:100%">
    	<!--  tieu de -->
    	<h:panelGrid columns="3" styleClass="columPanelbaritemTitle">
					<h:graphicImage value="/templates/default/images/left-heading_01.jpg" style="margin-left:-4px;margin-bottom:0px"></h:graphicImage>
			  		<h:outputText value="Giao nhận hộ chiếu" styleClass="panelbaritemTitle"></h:outputText>
					<h:graphicImage value="/templates/default/images/left-heading_03.jpg"></h:graphicImage>
		 </h:panelGrid>
	  	<!-- ket thuc tieu de -->
		<!-- phan noi dung phia duoi -->	  
    	<h:panelGrid columns="1" styleClass="panelGridBody">
    			<!-- Bat dau noi dung ben trong -->
		    <rich:panel style="background:#FFFFFF">
		    	<h:panelGrid columns="1" style="margin-left:13px;">
		       		<h:outputText id="idError" value="#{thongTinHC.error}" style=" color: red;"></h:outputText>
				</h:panelGrid>
				<h:outputText value="Thông tin cố định của hộ chiếu" style=" color: red;"></h:outputText>
				<h:panelGrid columns="2" style="margin-left:13px;">
		     		<h:outputText value="Số HC(*) : " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		    		<h:inputText id="soHC" value="#{thongTinHC.soHC}" style="margin-left:12px;"  size="20">
		    		<a4j:support event="onblur" reRender="ten" 
						action="#{thongTinHC.getInfor}"/>
		    		</h:inputText>
		    		
		    		<h:outputText value="Tên : " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		    		<h:inputText id="ten" readonly="true" value="#{thongTinHC.ten}" style="margin-left:12px;"  size="20"/>
		    		
		    		<h:outputText value="Giới tính: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		    		<h:inputText id="gioiTinh" readonly="true" value="#{thongTinHC.gioiTinh}" style="margin-left:12px;" size="10"/>
		    		
		     		<h:outputText value="Năm sinh: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		    		<h:inputText id="namSinh" readonly="true" value="#{thongTinHC.namSinh}" style="margin-left:12px;" size="8"/>
		    	    		   		
		       		<h:outputText value="Cơ quan :" style="margin-left:20px;" styleClass="inputText" >
		       		</h:outputText>
		       	  	<h:inputText id="coQuan" readonly="true" value="#{thongTinHC.coQuan}" style="margin-left:12px;" size="45"/>
		    	  		    	
		       		<h:outputText value="Loại HC: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       		<h:inputText id="loaiHC" readonly="true" value="#{thongTinHC.loaiHC}" style="margin-left:12px;" size="30"/>
				     
				   <h:outputText value="Ngày cấp: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <h:inputText id="ngayCap" readonly="true" style="margin-left:12px;" value="#{thongTinHC.ngayCap}" size="20"/>
		       	 
					<h:outputText value="Ngày hết hạn: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
					 <h:inputText id="ngayHetHan" readonly="true" style="margin-left:12px;" value="#{thongTinHC.ngayHetHan}" size="20"/>
		       	 
		       	 	<h:outputText value="Nơi cấp: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <h:inputText id="noiCap" readonly="true" style="margin-left:12px;" value="#{thongTinHC.noiCap}" size="45"/>
		       	   
		       	   	</h:panelGrid>
		     	
		     	<h:outputText value="Thông tin giao nhận hộ chiếu" style=" color: red;"></h:outputText>
				<h:panelGrid columns="3" style="margin-left:13px;">
					<h:outputText value="Thao tác(*): " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <h:selectOneRadio style="margin-left:33px;" value="#{thongTinHC.thaoTac}">
  						<f:selectItem itemValue="G" itemLabel="Giao"/>
  						<f:selectItem itemValue="N" itemLabel="Nhận"/>
  						<a4j:support event="onclick" reRender="nuocDen" 
						action="#{thongTinHC.displayInforQD}"/>
   					</h:selectOneRadio>		       	    	
				</h:panelGrid>
				<h:panelGrid columns="2" style="margin-left:13px;">
					<h:outputText value="Ngày thực hiện(*): " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <rich:calendar popup="true" id="ngayThucHien" size="5px" value="#{thongTinHC.ngayThucHien}" datePattern="dd/MM/yyyy" currentDate="#{thongTinHC.ngayThucHien}">
					</rich:calendar>
					
					<h:outputText value="Số QĐ(*): " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <h:inputText id="soQD" readonly="#{thongTinHC.state}" value="#{thongTinHC.soQD}" size="15">
		       	    <a4j:support event="onblur" reRender="nuocDen" 
						action="#{thongTinHC.thongTinThaoTac}"/>
		       	    </h:inputText>
		       	    
		       	    <h:outputText value="Nước đến: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <h:inputText id="nuocDen" readonly="true" value="#{thongTinHC.nuocDen}" size="45"/>
		       	    
		       	    <h:outputText value="Ngày đi: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <rich:calendar popup="true" id="ngayDi" readonly="true" size="5px" value="#{thongTinHC.ngayDi}" datePattern="dd/MM/yyyy" currentDate="#{thongTinHC.ngayDi}">
					</rich:calendar>
					
					<h:outputText value="Ngày về: " style="margin-left:20px;" styleClass="inputText" ></h:outputText>
		       	    <rich:calendar popup="true" id="ngayVe" size="5px" readonly="true" value="#{thongTinHC.ngayVe}" datePattern="dd/MM/yyyy" currentDate="#{thongTinHC.ngayVe}">
					</rich:calendar>
				</h:panelGrid>	
				
				<h:panelGrid columns="3" style="margin-left:13px;">
			    	<h:outputText value="Nộp HC: "  styleClass="inputText" style="margin-left:20px;"></h:outputText>
		    		<h:selectBooleanCheckbox style="margin-left:47px;" value="#{thongTinHC.nopHC}">
               		</h:selectBooleanCheckbox>
					<h:outputText value="(Check vào khi hộ chiếu được nộp) " style="color: red;"></h:outputText>
		    		
				</h:panelGrid>	
				<h:panelGrid columns="2" style="margin-left:190px;margin-top:10px;margin-bottom:1px">
			    	<a4j:commandButton value="Thực hiện" size="15" styleClass="Button" action="#{thongTinHC.thucHien}">
			    	</a4j:commandButton>			    
		       		<a4j:commandButton type="Button" size="15" value="Hủy bỏ" styleClass="Button" action="#{thongTinHC.huyBo}"></a4j:commandButton>
			      	</h:panelGrid>	
			         
		</rich:panel>		
	 </h:panelGrid>
   </h:panelGrid>
   </h:form>
 </ui:define>
</ui:composition> 
</body>	
</html>